import {getSupGoods} from "../service/supGoods.js"
export default {
	namespaced: true, //开启命名空间
	state: {
		listData: [],
		ruleForm:{
			imgs:{
				bigImg:[],
				smlImg:[]
			}
		},
		visible:false,
	},
	mutations: {
		setListData(state, listData) {
			state.listData = listData;
		},
		setRuleForm(state, ruleForm) {
			state.ruleForm = ruleForm;
		},
		setVisible(state, visible) {
			state.visible = visible;
		},
	},
	actions: {
		async show({commit,state}) {
			const data = await getSupGoods()
			commit("setListData", data)
		}
	},
}
